<!--Admin Main Menu-->
<!DOCTYPE HTML>
<html>
    <head>
     <link  rel="stylesheet" type="text/css" href = "stylesheet.css"/>
        
    </head>
    <body>
        
    <?php
    //get current day, month, and year and save to session variables which are passed on to admin_calendar.php
    session_start();
    $today = date("Y-m-d");
        
        
    $_SESSION['formYear'] = "";
    //YEAR
    for($i =0; $i <4; $i++)
    {
        $yearArray[$i] = $today[$i];  
    }
    //convert array to string
    $_SESSION['formYear'] = implode("", $yearArray);
    $_SESSION['formMonth'] = "";
    $count1= 0;
    //MONTH
    for($i = 5; $i < 7; $i++)
    {
        $monthArray[$count1] = $today[$i];
        $count1++;
    }
    //convert array to string
    $_SESSION['formMonth'] = implode("", $monthArray);
    $_SESSION['formDay'] = "";
    $count1 = 0;
    //DAY
    for($i = 8; $i <10; $i++)
    {
        $dayArray[$count1] = $today[$i];
        $count1++;
    }
    //convert array to string
    $_SESSION['formDay'] = implode("", $dayArray);
  
        
        
    
    ?>
        <h1 align = "center"><font face = 'Edwardian Script ITC'>Main Menu</font></h1>
        <!--Buttons for admin users-->
        <?php
        echo "<h3>Welcome ";
        echo $_SESSION['username'];
        echo "</h3>";
        ?>
        <center>
       
        <!--redirect to admin calendar view-->
        <form method="" action="admin_calendar.php">
            <input value ="View Calendar" type="submit" class = "menu"/>
        </form>
       <br>
        
        <form method="" action="view-schedule.php">
            <input value = "View Schedule" type="submit" class = "menu"/ >
        </form><br>
        
        <form method="" action="view_contacts.php">
            <input value = "View Contacts" type="submit" class = "menu" >
        </form><br>
        
         <form method="" action="add_edit_delete_users.php">
            <input value = "Add/Update Users" type="submit" class = "menu" >
        </form><br>
        
        <form method="" action="login.php">
            <input value = "Log Out" type="submit" class = "menu" >
        </form><br>
        </center>
        
    </body>
</html>